package com.um.springboot.starter.properties;

import com.um.springboot.starter.constants.SmsConsts;
import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

import java.util.LinkedHashMap;
import java.util.Map;

/**
 * @author 甘天伟
 * @since 2024/5/7
 * 版权所有 广州优匠科技有限公司
 */
@Data
@Configuration
@ConfigurationProperties("hsh.alibaba-cloud-sms")
public class AlibabaCloudSmsProperties {
    /**
     * 区域
     */
    private String regionId = "ap-southeast-1";
    /**
     * AccessKey ID
     */
    private String accessKeyId;
    /**
     * AccessKey Secret
     */
    private String accessKeySecret;
    /**
     * 发送方号码或SenderID
     */
    private String from;
    /**
     * 短信模板
     */
    private Map<String, String> templates = new LinkedHashMap<>();

    public AlibabaCloudSmsProperties() {
        templates.put(SmsConsts.VERIFICATION_CODE_TEMPLATE, "Your verification code is: {}");
    }
}
